#ifndef _GENERATION_NAME
#define _GENERATION_NAME

#include <ctime>
#include <iostream>
#include <string>
#include <sstream>
#include <cstdlib>
#include <cstdio>

using namespace std;

class G_Name
{
  string out_file;
  unsigned long int cpt;
  string log;

public:
  G_Name();
  G_Name(string log);

  string get_name();
  void next_name();

  void rand_name(unsigned int cpt);

  ~G_Name()
  {};

private:
  string to_string(int d)const
  {
    string r_to_string="";
    int rest=0;


    do
      {
	rest=d%10;
	d/=10;
	
	switch(rest)
	  {
	  case 0:
	    r_to_string="0"+r_to_string;
	    break;
	  case 1:
	    r_to_string="1"+r_to_string;
	    break;
	  case 2:
	    r_to_string="2"+r_to_string;
	    break;
	  case 3:
	    r_to_string="3"+r_to_string;
	    break;
	  case 4:
	    r_to_string="4"+r_to_string;
	    break;
	  case 5:
	    r_to_string="5"+r_to_string;
	    break;
	  case 6:
	    r_to_string="6"+r_to_string;
	    break;
	  case 7:
	    r_to_string="7"+r_to_string;
	    break;
	  case 8:
	    r_to_string="8"+r_to_string;
	    break;
	  case 9:
	    r_to_string="9"+r_to_string;
	    break;
	  default:
	    break;
	  }
      }while(d != 0);
    return r_to_string;
  };

};

#endif
